- /* srmsetsl.cpp by K.Tsuru */
- // function ID = 801 DRADIX, BRADIX
- /*****************************
- SRational class
- set a value by SLong or SInteger
- ******************************/
- #ifndef SN_H
- #include "sn.h"
- #endif
- void SRational::Set(const SLong& n, const SLong& d){
- if(n.Type() != d.Type()) n.SetError(n.RADIX_ERR, "SR Set", 801);
- if(n.Type() == n.INTEGER){ // SLong
- SInteger t;
- num = t.ConvToBin(n); den = t.ConvToBin(d);
- } else { // SInteger
- num = n; den = d;
- }
- reduceDone = false;
- RadixCheck(); DenCheck();
- reduce(false);
- }
srmsetsl.cpp : last modifiled at 2016/06/26 16:29:28(586 bytes)
created at 2016/06/26 15:57:35
The creation time of this html file is 2016/09/18 20:28:05 (Sun Sep 18 20:28:05 2016).